/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package entities;

import java.io.Serializable;
import java.util.Date;
import java.util.List;
import javax.xml.bind.annotation.XmlTransient;

/**
 *
 * @author Andrés Felipe
 */
public class Product implements Serializable {
    private static final long serialVersionUID = 1L;
    private Integer idproduct;
    private String name;
    private double price;
    private double quantity;
    private double capacity;
    private Date productionabledate;
    private int tosell;
    private double howmanythisday;
    private double productiontime;
    private List<RequestXproduct> requestXproductList;
    private List<ProductXsales> productXsalesList;
    private List<SupplierXproduct> supplierXproductList;
    private List<ProductStructure> productStructureList;
    private List<ProductStructure> productStructureList1;
    private Pyme pymeidentification;

    public Product() {
    }

    public Product(Integer idproduct) {
        this.idproduct = idproduct;
    }

    public Product(Integer idproduct, String name, double price, double quantity, double capacity, Date productionabledate, int tosell, double howmanythisday, double productiontime) {
        this.idproduct = idproduct;
        this.name = name;
        this.price = price;
        this.quantity = quantity;
        this.capacity = capacity;
        this.productionabledate = productionabledate;
        this.tosell = tosell;
        this.howmanythisday = howmanythisday;
        this.productiontime = productiontime;
    }

    public Integer getIdproduct() {
        return idproduct;
    }

    public void setIdproduct(Integer idproduct) {
        this.idproduct = idproduct;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public double getQuantity() {
        return quantity;
    }

    public void setQuantity(double quantity) {
        this.quantity = quantity;
    }

    public double getCapacity() {
        return capacity;
    }

    public void setCapacity(double capacity) {
        this.capacity = capacity;
    }

    public Date getProductionabledate() {
        return productionabledate;
    }

    public void setProductionabledate(Date productionabledate) {
        this.productionabledate = productionabledate;
    }

    public int getTosell() {
        return tosell;
    }

    public void setTosell(int tosell) {
        this.tosell = tosell;
    }

    public double getHowmanythisday() {
        return howmanythisday;
    }

    public void setHowmanythisday(double howmanythisday) {
        this.howmanythisday = howmanythisday;
    }

    public double getProductiontime() {
        return productiontime;
    }

    public void setProductiontime(double productiontime) {
        this.productiontime = productiontime;
    }

    @XmlTransient
    public List<RequestXproduct> getRequestXproductList() {
        return requestXproductList;
    }

    public void setRequestXproductList(List<RequestXproduct> requestXproductList) {
        this.requestXproductList = requestXproductList;
    }

    @XmlTransient
    public List<ProductXsales> getProductXsalesList() {
        return productXsalesList;
    }

    public void setProductXsalesList(List<ProductXsales> productXsalesList) {
        this.productXsalesList = productXsalesList;
    }

    @XmlTransient
    public List<SupplierXproduct> getSupplierXproductList() {
        return supplierXproductList;
    }

    public void setSupplierXproductList(List<SupplierXproduct> supplierXproductList) {
        this.supplierXproductList = supplierXproductList;
    }

    @XmlTransient
    public List<ProductStructure> getProductStructureList() {
        return productStructureList;
    }

    public void setProductStructureList(List<ProductStructure> productStructureList) {
        this.productStructureList = productStructureList;
    }

    @XmlTransient
    public List<ProductStructure> getProductStructureList1() {
        return productStructureList1;
    }

    public void setProductStructureList1(List<ProductStructure> productStructureList1) {
        this.productStructureList1 = productStructureList1;
    }

    public Pyme getPymeidentification() {
        return pymeidentification;
    }

    public void setPymeidentification(Pyme pymeidentification) {
        this.pymeidentification = pymeidentification;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (idproduct != null ? idproduct.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Product)) {
            return false;
        }
        Product other = (Product) object;
        if ((this.idproduct == null && other.idproduct != null) || (this.idproduct != null && !this.idproduct.equals(other.idproduct))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "entities.Product[ idproduct=" + idproduct + " ]";
    }
    
}
